---
slug: /plugins/reset-node
title: Reset Node
---

### `createResetNodePlugin`

Allows you to reset the block type based on certain rules.

In the following example, you can press `Enter` in an empty block quote or `Backspace` at the start of a block so it resets to a paragraph.

```ts live
() => {
  const resetBlockTypesCommonRule = {
    types: [ELEMENT_BLOCKQUOTE, ELEMENT_TODO_LI],
    defaultType: ELEMENT_PARAGRAPH,
  };

  const optionsResetBlockTypePlugin = {
    rules: [
      {
        ...resetBlockTypesCommonRule,
        hotkey: 'Enter',
        predicate: isBlockAboveEmpty,
      },
      {
        ...resetBlockTypesCommonRule,
        hotkey: 'Backspace',
        predicate: isSelectionAtBlockStart,
      },
    ],
  };

  const plugins = [
    ...pluginsBasic,
    createListPlugin(),
    createTablePlugin(),
    createResetNodePlugin(optionsResetBlockTypePlugin),
    createSoftBreakPlugin(optionsSoftBreakPlugin),
    createExitBreakPlugin(optionsExitBreakPlugin),
    createTrailingBlockPlugin({ type: ELEMENT_PARAGRAPH }),
  ];

  return (
    <Plate
      id="reset-node"
      plugins={plugins}
      components={components}
      options={options}
      editableProps={editableProps}
      initialValue={initialValueBasicElements}
    />
  );
}
```
